🔒 PROJECT FREEZE — USERS MODULE (LOCKED)

users.html is considered functionally correct

Known edge cases are accepted for now

No further refactors unless explicitly reopened

All hierarchy, RSP enforcement, and self-protection rules are preserved

This chat is now closed for active development

🚀 NEW CHAT BOOTSTRAP (COPY THIS EXACTLY)

Paste the following as your first message in the new chat:

TechStackBase – Admin Platform Bootstrap

You are working on TechStackBase, a multi-tenant admin platform with:

Stack

Frontend: vanilla HTML / JS (admin UI)

Backend: PHP (strict, PDO, JSON-only APIs)

Auth: session-based (admin UI) + bearer token (API)

DB: MySQL

No frameworks, no ORMs

Authoritative Rules

Backend is authoritative

Frontend must never bypass backend validation

All endpoints return { status, message?, data? }

All admin changes are audited

Session invalidation is enforced on:

role change

company change

status != active

Role Hierarchy (strict)
super_admin
platform_admin
rsp_admin
company_admin
user


Cannot assign equal or higher role

Cannot modify own role, company, or status

RSP admins:

Can only manage users in their RSP

Cannot assign platform/super roles

Can only move users between companies in their RSP

Current Module Status

✅ Auth system: working

✅ Companies: working

✅ Modules: working

✅ Subscriptions: working

🔒 Users: FROZEN / ACCEPTED

❌ Billing: not started

❌ Plans: not started

Users Module (LOCKED)

users.html accepted as final for now

users/list.php returns:

{
  "status": "success",
  "data": {
    "users": [...],
    "total": <int>
  }
}


users/admin_update.php enforces:

hierarchy

RSP scope

self-protection

session invalidation

audit logging

Do not re-architect Users unless explicitly instructed.

Next Work Starts At

👉 State clearly what we are doing next (e.g. Audit UI, Billing, Dashboard KPIs, Kotlin API mirror, etc.)

🧠 WHY THIS WORKS

This bootstrap:

Prevents context drift

Locks in decisions already made

Stops accidental rewrites

Keeps velocity high in future chats

Lets us pick up exactly where we left off

When you’re ready, start a new chat, paste the bootstrap, and say something like:

“Next: Audit log UI filtering”
or
“Next: Kotlin backend mirror for users”
or
“Next: Billing foundations”

I’ll snap straight into the correct mode.